/*
package io.renren.config;

import mybatis.mate.annotation.FieldBind;
import mybatis.mate.sets.IDataBind;
import org.apache.ibatis.reflection.MetaObject;
import org.springframework.stereotype.Component;

import java.util.Map;
import java.util.concurrent.ConcurrentHashMap;

@Component
public class DataBind implements IDataBind {


  */
/**
   * 从数据库或缓存中获取
   *//*

  private Map<String, String> SEX_MAP = new ConcurrentHashMap<String, String>() {{
    put("0", "女");
    put("1", "男");
  }};


  @Override
  public void setMetaObject(FieldBind fieldBind, Object fieldValue, MetaObject metaObject) {
    System.err.println("字段类型：" + fieldBind.type() + "，绑定属性值：" + fieldValue);
    metaObject.setValue(fieldBind.target(), SEX_MAP.get(String.valueOf(fieldValue)));
  }
}*/
